def E(t):
    for b in range(2, int(t**0.5)+1):
        if t%b==0:
            break
        else:
            print("Простое")
            break
numbers=["zero", "one", "two", "three", "four", "five", "six", "seven", "eight", "nine"]
A=input().split()
if len(A)!=3:
    print('Wrong input')
else:
    for i in range(3):
        if A[i] not in numbers:
            print("Wrong input")
            break
for i in range(10):
    if A[0]==numbers[i]:
        x=i*100
    if A[1]==numbers[i]:
        y=i*10
    if  A[2]==numbers[i]:
        z=i
s=x+y+z
E(s)
print(s)
